﻿using ProTrack.Entity;
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;

namespace ProTrack.IServices.Plans
{
    public interface ITeamServices
    {
        /// <summary>
        /// 新增
        /// </summary>
        /// <param name="model">数据模型</param>
        /// <returns></returns>
        public Task<bool> AddAsync(Team model, List<TeamMember> list);
        /// <summary>
        /// 根据班组编号 获取 班组附加表
        /// </summary>
        /// <param name="TeamCode">班组编号</param>
        /// <returns></returns>
        public Task<IEnumerable<TeamMember>> GetTeamMemberbyCodeAsync(string TeamCode);

        /// <summary>
        /// 查询所有
        /// </summary>
        /// <returns></returns>
        public Task<IEnumerable<Team>> GetAllAsync();
        /// <summary>
        /// 分页获取
        /// </summary>
        /// <param name="PageIndex">当前页</param>
        /// <param name="PageSize">页大小</param>
        /// <param name="TeamType">班组类型</param>
        /// <param name="TeamCode">班组编号</param>
        /// <param name="TeamName">班组名称</param>
        /// <returns></returns>
        public Task<IEnumerable<Team>> GetAsync(int PageIndex, int PageSize, string TeamType, string TeamCode, string TeamName);
        /// <summary>
        /// 获取总条数
        /// </summary>
        /// <param name="TeamType">班组类型</param>
        /// <param name="TeamCode">班组编号</param>
        /// <param name="TeamName">班组名称</param>
        /// <returns></returns>
        public Task<int> GetCountAsync(string TeamType, string TeamCode,string TeamName);
        /// <summary>
        /// 修改
        /// </summary>
        /// <param name="model">数据模型</param>
        /// <param name="list">子数据集合</param>
        /// <returns></returns>
        public Task<bool> UpdateAsync(Team model, List<TeamMember> list);

        /// <summary>
        /// 批量删除
        /// </summary>
        /// <param name="Ids"></param>
        /// <returns></returns>
        public Task<bool> DeleteAsync(int[] Ids);
        /// <summary>
        /// 删除
        /// </summary>
        /// <param name="Id"></param>
        /// <returns></returns>
        public Task<bool> DeleteAsync(int Id);




        /// <summary>
        /// 获取全部员工  
        /// </summary>
        /// <returns></returns>
        public Task<IEnumerable<Employees>> GetTeamTypeAllAsync();


    }
}
